package com.snow.admin.controller;

import com.snow.admin.dao.SysUserMapper;
import com.snow.admin.domain.SysUser;
import com.snow.admin.service.ISnowFlakeService;
import com.snow.datasource.annoation.Snow;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Description
 * @Author fanxl 315620726@qq.com
 * @Date 2020/12/9
 **/
@RestController
@RequestMapping("/snowflake")
public class SnowFlakeController {

    @Autowired
    private ISnowFlakeService iSnowFlakeService;

    @RequestMapping("/get")
    public Object getSnowFlake(){
        List<SysUser> sysUserList = iSnowFlakeService.getUserList();
        return sysUserList;
    }
    @RequestMapping("/get2")
    @Snow
    public Object getSnowFlake2(){
        List<SysUser> sysUserList = iSnowFlakeService.getUserList();
        return sysUserList;
    }
}
